<%@ page language="java" contentType="text/html; charset=ISO-8859-1" pageEncoding="ISO-8859-1"%>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<%@page import="com.appspot.zarm.gomoku.GomokuBoardFactory"%>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">

<link rel="stylesheet" type="text/css" href="css/layout.css">
<script type="text/javascript" src="js/layout.js"></script>
<script type="text/javascript" src="js/transport.js"></script>
<script type="text/javascript" src="js/jquery-1.8.0.js"></script>
<script type="text/javascript" src="js/jquery.json-2.3.js"></script>
<script type="text/javascript">
// init 
	$(document).ready( function() {
		boardSize = <%=GomokuBoardFactory.BOARD_SIZE%>;
		createBoard();
		
		$("#board").hide();
		$("#finish").hide();
		
		$("#start").click(function() {
			$(this).hide();
			$("#board").show();
			$("#finish").show();
			doStart();
		});
		
		$("#finish").click(function() {
			$(this).hide();
			clearBoard();
			$("#board").hide();
			$("#start").show();
			doFinish();
		});
	});
</script>

<title>Main layout</title>
</head>
<body>

<table border="1" width="100%" class="fade">
	<tbody>
		<tr>
			<td colspan="3">Header</td>
		</tr>
		<tr>
			<td width="20%">
				Menu:
				<br>
				<input type="button" id="start" value="start">
				<input type="button" id="finish" value="finish">
			</td>
			<td>
				<table id="board" border="1">
					<tbody>
					</tbody>
				</table>
			</td>
			<td width="20%">Reserve</td>
		</tr>
		<tr>
			<td colspan="3">Footer</td>
		</tr>
	</tbody>
</table>

</body>
</html>